package com.lrkj.back.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

public class TbModule implements Serializable,Comparable<TbModule>{
    /**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	private Integer moduleId;

    private String moduleName;

    private Integer moduleType;

    private String moduleUrl;

    private Integer moduleParent = null;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss" ,timezone="GMT+8")
    private Date moduleCreatetime;

    private Integer moduleIsover = 1;
    
    private Integer moduleOrder;

    private String checked = "" ; //
    
    public Integer getModuleId() {
        return moduleId;
    }

    public void setModuleId(Integer moduleId) {
        this.moduleId = moduleId;
    }

    public String getModuleName() {
        return moduleName;
    }

    public void setModuleName(String moduleName) {
        this.moduleName = moduleName == null ? null : moduleName.trim();
    }

    public Integer getModuleType() {
        return moduleType;
    }

    public void setModuleType(Integer moduleType) {
        this.moduleType = moduleType;
    }

    public String getModuleUrl() {
        return moduleUrl;
    }

    public void setModuleUrl(String moduleUrl) {
        this.moduleUrl = moduleUrl == null ? null : moduleUrl.trim();
    }

    public Integer getModuleParent() {
        return moduleParent;
    }

    public void setModuleParent(Integer moduleParent) {
        this.moduleParent = moduleParent;
    }

    public Date getModuleCreatetime() {
        return moduleCreatetime;
    }

    public void setModuleCreatetime(Date moduleCreatetime) {
        this.moduleCreatetime = moduleCreatetime;
    }

    public Integer getModuleIsover() {
        return moduleIsover;
    }

    public void setModuleIsover(Integer moduleIsover) {
        this.moduleIsover = moduleIsover;
    }

	@Override
	public String toString() {
		return "TbModule [moduleId=" + moduleId + ", moduleName=" + moduleName
				+ ", moduleType=" + moduleType + ", moduleUrl=" + moduleUrl
				+ ", moduleParent=" + moduleParent + ", moduleCreatetime="
				+ moduleCreatetime + ", moduleIsover=" + moduleIsover + "]";
	}

	public String getChecked() {
		return checked;
	}

	public void setChecked(String checked) {
		this.checked = checked;
	}

	public Integer getModuleOrder() {
		return moduleOrder;
	}

	public void setModuleOrder(Integer moduleOrder) {
		this.moduleOrder = moduleOrder;
	}

    @Override
    public int compareTo(TbModule o) {
        return this.getModuleId()-o.getModuleId();
    }
}